home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC Zone 92
/
DPPCZ0800.7z
/
DPPCZ0800.ISO
/
Demos
/
Star Trek - Armada
/
armada_demo.exe
/
data
/
Collision.cfg
< prev
next >
Wrap
Text File
|
1999-09-17
|
4KB
|
115 lines
///////////////////////////////////////////////////////////////////////////////
//
// Collision.cfg
//
// This files contains runtime configuration variables for collision avoidance.
//
// By the Mad Dr. I
//
///////////////////////////////////////////////////////////////////////////////
// Which revision of this file are we using?
#define COLLISION_CONFIG_FILE_REVISION 1
// Range Search Parameters
#define AVOIDANCE_USING_RANGE_SEARCH 1
// How big is a grid cell in the range search structure?
#define GRID_X_SIZE 256.0
#define GRID_Z_SIZE 256.0
// Which modes are on?
// Any or all of the following four modes can be selected or deselected
// together.
// The combo most like the old avoidance is (1,0,0,0).
// The one recommended by the doctor is (1,1,1,0)
// COLLISION_DIRECT_REPULSION is a repulsive force pointing directly
// at one object from another.
#define COLLISION_DIRECT_REPULSION 0
// COLLISION_LATERAL_REPULSION is a force which causes one object to move
// laterally to take another object out of its direct path. This keeps two
// objects from being is a "standoff" facing each other trying to get by.
#define COLLISION_LATERAL_REPULSION 1
// COLLISION_FULL_POTENTIAL_FIELD uses forces from all really close objects
// if its value is 1. Otherwise, the repulsion is only from the single
// closest obstacle. This makes a noticable difference when several objects
// are close together (cuts down collisions)
#define COLLISION_FULL_POTENTIAL_FIELD 1
// COLLISION_REAL_COLLISIONS turns on a check (when 1) to see if two objects
// really could collide given their current velocities. If not, forces are
// nott applied. This is potentially expensive, and the parameters would need
// to be tweaked carefully to avoid collisions.
#define COLLISION_REAL_COLLISIONS 0
// COLLISION_MARTIN_REPULSION uses Martin^2's famous avoidance algorithm
#define COLLISION_MARTIN_REPULSION 0
///////////////////////////////////////////////////////////////////////////////
// FOR Lateral Repulsion
// This is a modifier for the magnitude of lateral
// forces applied for avoidance
#define LATERAL_AVOIDANCE_MULTIPLIER 120.0 // Was 120.0
// This is how many times bigger the danger zone for a collision
// can be than the combined radius of the two objects
#define LATERAL_DANGER_WIDTH 1.0
///////////////////////////////////////////////////////////////////////////////
// FOR AIUtil_Detect_2D_Collision
// When we're looking to see if there will be a collision with an object
// in some time period, what is the time we say (in seconds)
#define COLLISION_LOOK_AHEAD_TIME 10.0 // Was 2.5
// When doing the Real Collision Look ahead, how much bigger than the
// real radius of objects do we consider the objects to be...
#define COLLISION_SAFETY_COEFF 1.5
// Should we use the cheap 2D collision or the expensive one?
#define COLLISION_CHEAP_2D_COLLIDE 0
///////////////////////////////////////////////////////////////////////////////
// FOR FindPotentialField
// How much more attractive is the final goal than a waypoint?
#define EXTRA_GOAL_ATTRACTION 5.0
// Simple multiplier for the effect of repulsion
#define REPULSIVE_COEFFICIENT 1200.0
// Simple multiplier for the effect of the new (Martin's) repulsion formula
// Not used anymore, since this is now stored in the ODF file.
#define NEW_REPULSIVE_COEFFICIENT 600.0
// By default how far away do we cut off the repulsive effect of an object
// (in meters)
#define DEFAULT_REPULSION_CUTOFF 300.0
// Default distance for potential field influence of repulsion
#define DISTANCE_OF_INFLUENCE 110.0
///////////////////////////////////////////////////////////////////////////////
// FOR CliffForce
// Additional coefficient for cliffs' repulsive force
#define CLIFF_REPULSION_COEFFICIENT 1.0 // was 3.0
///////////////////////////////////////////////////////////////////////////////
// FOR GotoTask::Goto(void)
// How close to a point on our path should we be before we start heading to
// the next point
#define SWITCH_TO_NEXT_POINT_DISTANCE 20.0
///////////////////////////////////////////////////////////////////////////////
// FOR UnitTask::IsStuck(void)
// Give some extra time before we call a unit stuck!
#define EXTRA_STUCK_TIME 5.0